work done by a spring physics